Skip to content

Check valid path before deleting#106

Merged
rkoopmans merged 15 commits intotinify:masterfrom
wcreateweb:check-valid-path-before-deleting
May 7, 2026
Merged

Check valid path before deleting#106
rkoopmans merged 15 commits intotinify:masterfrom
wcreateweb:check-valid-path-before-deleting

Conversation

@tijmenbruggeman
Copy link
Copy Markdown
Collaborator

@tijmenbruggeman tijmenbruggeman commented May 7, 2026

We will only be storing images in the uploads directory. Adding this check together with realpath will ensure that we will only be deleting the intended file.

The str_starts_with helper is taken from #98

@rkoopmans rkoopmans merged commit 4fa01ad into tinify:master May 7, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants